<!DOCTYPE html>
<html lang="en">
    <head>
        <title></title>
        <meta charset="UTF-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <script src="./vue2.js"></script>

        <style>
            .red-font{
                color:red;
            }
        </style>
    </head>
    <body>
        <div id="app">
            {{name}}
            <img v-bind:src="avatar" alt="">
            <img :src="avatar" alt=""><!-- 简洁写法 -->
            <a :href="'del.php?id='+id">删除</a>
            <a :class={"red-font":false}>红色字体</a>
        </div>
        <script>
            var vm = new Vue({
                el: '#app',
                data: {
                    name:"jack",
                    avatar:"avatar.jpg",
                    id:11
                }
            })
        </script>
    </body>
</html>